package com.cleaningcloud.erp.mapper;

import java.util.List;
import com.cleaningcloud.erp.domain.ErpReturnDetails;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Param;

/**
 * 退换货明细Mapper接口
 *
 * @author cleaningcloud
 * @date 2024-10-06
 */
public interface ErpReturnDetailsMapper
{
    /**
     * 批量新增销售退换货明细
     * @param list
     */
    void batchReturnDetailsInsert(List<ErpReturnDetails> list);


    /**
     * 根据退换货id批量删除明细
     * @param returnId
     */
    @Delete("delete from `cleaningcloud-erp`.erp_return_details where order_id = #{returnId}")
    void deleteByReturnId(@Param("returnId") Long returnId);
}
